{extend name="./public/base"/}
{block name="alt"}admin上传视频列表管理{/block}
{block name="alter"}视频列表{/block}
{block name="title"}BangBang修改视频信息{/block}
{block name="main"}
<div class="modal-body">
						<form class="form-horizontal" role="form" action="{:url('doupdate')}" method="post" enctype="multipart/form-data" >
{volist name="videoupdates" id="vi"}
<input type="hidden" name="vid" value="{$vi.vid}" >
<div class="form-group">
    <label for="inputPassword" class="col-sm-4 control-label">视频名称</label>
    <div class="col-sm-4">
      <input type="text" name="videoname" class="form-control" id="inputPassword" value="{$vi.videoname}">
    </div>
  </div>
 
  <div class="form-group">
    <label for="inputPassword" class="col-sm-4 control-label">视频类别</label>
    <div class="col-sm-4">
      <select class="form-control" name="tid">
      	<option value="{$vi.tid}">{$vi.typename}</option>
      	{volist name="types" id="ty"}
      <option value="{$ty.tid}">{$ty.typename}</option>
      {/volist}
    </select>
    </div>
  </div>
  <div class="form-group">
    <label for="inputPassword" class="col-sm-4 control-label">视频所属体系</label>
    <div class="col-sm-10">
       <select class="form-control" name="know" id="know" style="width: 11rem;" required> 
                    <option value="{$vi.kname}">原:{$vi.kname}</option>
                    {volist name="knows" id="kn"}
                    <option value="{$kn.kid}">{$kn.kname}</option>
                    {/volist}                           
                  </select>

          <select class="form-control" name="kbid" id="kboy" style="width: 11rem;" required>  
                    <option value="{$vi.kbname}">原:{$vi.kbname}</option>  
                  </select>
    </div>
  </div>

  <div class="form-group">
    <label for="inputPassword" class="col-sm-4 control-label">视频所属职业方向</label>
    <div class="col-sm-10">
       <select class="form-control" name="oid"  style="width: 11rem;" required> 
                    <option value="{$vi.oid}">原:{$vi.oname}</option>
                    {volist name="occs" id="oc"}
                    <option value="{$oc.oid}">{$oc.oname}</option>
                    {/volist}                           
                  </select>

          <select class="form-control" name="olevel"  style="width: 11rem;" required>  
                    <option value="{$vi.olevel}">原:{if condition="$vi.olevel==1"}入门
      {elseif condition="$vi.olevel==2"/}基础
      {elseif condition="$vi.olevel==3"/}初级工程师
      {else/}中级工程师
      {/if}</option>  
      <option value="1">入门</option>
      <option value="2">基础</option>
      <option value="3">初级工程师</option>
      <option value="4">中级工程师</option>
                  </select>
    </div>
  </div>
  
  
  <div class="form-group">
    <label for="inputPassword" class="col-sm-4 control-label">视频海报</label>
    <div class="col-sm-4">
      <input type="file" name="pic" class="form-control" id="inputPassword" >
      <br>
      <br>
       <img src="__STATIC__/videopic/{$vi.pic}" width="70px" height="70px" >
       <span>原视频海报</span>
    </div>
  </div>
  <div class="form-group">
    <label for="inputPassword" class="col-sm-4 control-label">视频简介</label>
    <div class="col-sm-4">
      <textarea class="form-control" name="intro" rows="3" required value="">{$vi.intro}</textarea>
    </div>
  </div>
  {/volist}
  <button type="submit" class="btn btn-primary">SAVE</button>
</form>
         	 	</div>
<script src="__STATIC__/assets/plugins/jquery/jquery.min.js"></script>
<script>
  $(function(){
    $("#know").change(function(){
      $.get("{:url('show')}",{know:$("#know").val()},function(data){
        $("#kboy").html(data);
      });
    });
  })
</script>


            {/block}